{foreach key="ForecastIndex" name="forecasts" item="itemForecast" from=$forecast}
<Header>
ProviderName=Intelli4x
SendFrom=alerts@intelli4x.com
SignalSubject=TP and SL update for signal started at {$itemForecast.BeginTime|date_format:"%m/%d/%Y"}
NumberOfSignals=1
</Header>
<Signal>
SystemName=IntelliForex-IntraDay
SubsystemName={$itemForecast.ForecastID}
Command=ModifyOrder
SubCommand=Modify
BuySell={if $itemForecast.Side == 0}Buy{elseif $itemForecast.Side==1 }Sell{/if}

Currency={$itemForecast.Pair|replace:"/":""}
Rate=Market
StopLoss={$itemForecast.StopPrice}
TakeProfit={$itemForecast.EndPrice}
NumPositions=1
</Signal>
{/foreach}